<!--
 * @Author: your name
 * @Date: 2021-08-19 14:42:01
 * @LastEditTime: 2021-08-19 15:04:10
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \briup\4-云服务器\day01\1-flex布局.html
-->
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>flex布局</title>
    <style>
        .parent {
            height: 300px;
            border: 1px solid red;
            display: flex;
            /* 在主轴方向的排列方式 默认是x轴 */
            justify-content: flex-start;
            justify-content: flex-end;
            justify-content: center;
            justify-content: space-between;
            /* 左右下都有空间 */
            justify-content: space-around;
            /* 平均分配 */
            justify-content: space-evenly;
            /* 在交叉轴的对齐方式 */
            align-items: flex-start;
            align-items: flex-end;
            align-items: center;
            /* 基线对齐 文本对齐 */
            align-items: baseline;
            /* 拉伸 */
            align-items: stretch;
        }
        
        .child {
            width: 200px;
            /* height: 200px; */
            border: 1px solid blue;
        }
        /* .child:nth-child(2) {
            /* padding-top: 20px; */
        /* } */
    </style>
</head>

<body>
    <div class="parent">
        <div class="child">1</div>
        <div class="child">2</div>
        <div class="child">3</div>

    </div>
</body>

</html>

</html>

</html>

</html>

</html>

</html>

</html>